package com.hp.service.impl;

import com.hp.entity.Department;
import com.hp.entity.Patient;
import com.hp.mapper.DepartmentMapper;
import com.hp.service.DepartmentService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class DepartmentServiceImpl implements DepartmentService {
    @Resource
    private DepartmentMapper departmentMapper;
    @Override
    public List<Department> findAll(Department department) {
        return departmentMapper.findAll(department);
    }

    @Override
    public Patient findById(Department department) {
        return departmentMapper.findById(department);
    }

    @Override
    public int delete(String[] id) {
        return departmentMapper.delete(id);
    }

    @Override
    public int add(Department department) {
        return departmentMapper.add(department);
    }

    @Override
    public int update(Department department) {
        return departmentMapper.update(department);
    }
}
